package com.example.ddz;

import java.util.Vector;

public class Player {
	  public static final int PLAYER_D = 3;
	  public static final int PLAYER_M = 1;
	  public static final int PLAYER_U = 2;
	  public boolean canOutAllTheWay = false;
	  public Vector<Card> cards;
	  public PlayersCardsInfo cardsInfo = null;
	  public int grade;
	  public boolean isCalling = false;
	  public boolean isDizhu = false;
	  public boolean isOutCarding = false;
	  private Vector<Card> outCards;
	  public int outCardsTimes = 0;
	  private int playerType;

	  public Player(int paramInt, Vector<Card> paramVector)
	  {
	    Vector localVector = new Vector();
	    this.outCards = localVector;
	    this.cards = paramVector;
	    this.playerType = paramInt;
	  }

	  public Vector<Card> getOutCards()
	  {
	    return this.outCards;
	  }

	  public int getPlayerType()
	  {
	    return this.playerType;
	  }

	  public void getUnderCards(Vector<Card> paramVector)
	  {
	    Vector localVector1 = AI.concatCards(this.cards, paramVector);
	    Vector localVector2 = AI.sortByBigOrSmall(this.cards);
	    this.cards = localVector2;
	  }

	  public void makeCards()
	  {
	    PlayersCardsInfo localPlayersCardsInfo = AI.makeCards(this.cards);
	    this.cardsInfo = localPlayersCardsInfo;
	  }

	  public boolean outCards(Vector<Card> paramVector)
	  {
	    Keeper.remove(this, paramVector);
	    Vector localVector = AI.sortByFaceAndSuit(paramVector);
	    this.outCards = localVector;
	    boolean bool = AI.deleteCards(this.cards, paramVector);
	    makeCards();
	    return bool;
	  }

	  public void setDizhu(Vector<Card> paramVector)
	  {
	    getUnderCards(paramVector);
	    makeCards();
	    this.isDizhu = true;
	  }

	  public void setOutCards(Vector<Card> paramVector)
	  {
	    this.outCards = paramVector;
	  }
}
